package com.hcloud.audit.api;

import feign.Logger;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 当某一个web项目引入此依赖时，自动配置对应的内容
 * 初始化log的事件监听与切面配置
 *
 * @Auther hepangui
 * @Date 2018/11/20
 */
@Configuration
@ConditionalOnWebApplication
@EnableFeignClients({"com.hcloud.audit.api.feign"})
public class LogAutoConfiguration {
    @Bean
    public Logger.Level feignLoggerLevel() {
        return Logger.Level.FULL;
    }

}
